package com.work.work2;

public  class Rabbit extends Animal{
    public Rabbit(){
    }
    public Rabbit(String name, String color, String category) {
        super(name, color, category);
    }
    @Override
    public void eat(){
        System.out.println("兔子是" + getCategory() + "，爱吃胡萝卜");
    }
    @Override
    public void shout(){
        System.out.println("正在叽叽的叫···");
    }
    public String toString(){
        return "那只" + getColor() + "的，名叫" + getName() + "的兔子正在" ;
    }
}
